Skip to content

new check: variables that should be quoted#379

Closed
laumann wants to merge 1 commit intopkgcore:masterfrom
laumann:unquoted-variables
Closed

new check: variables that should be quoted#379
laumann wants to merge 1 commit intopkgcore:masterfrom
laumann:unquoted-variables

Conversation

@laumann
Copy link
Copy Markdown
Contributor

@laumann laumann commented May 18, 2022

This is based on the repoman check EbuildQuote that reports instances of
some variables that should be quoted in certain contexts.

See: https://gitweb.gentoo.org/proj/portage.git/tree/repoman/lib/repoman/modules/linechecks/quotes/quotes.py?h=portage-3.0.30
Closes: #363
Signed-off-by: Thomas Bracht Laumann Jespersen t@laumann.xyz

@codecov
Copy link
Copy Markdown

codecov Bot commented May 18, 2022

Codecov Report

Merging #379 (88f7d96) into master (c2761ba) will decrease coverage by 0.03%.
The diff coverage is 89.74%.

❗ Current head 88f7d96 differs from pull request most recent head 078758a. Consider uploading reports for the commit 078758a to get more accurate results

@@            Coverage Diff             @@
##           master     #379      +/-   ##
==========================================
- Coverage   95.65%   95.61%   -0.04%     
==========================================
  Files          55       55              
  Lines        7573     7551      -22     
  Branches     1844     1842       -2     
==========================================
- Hits         7244     7220      -24     
- Misses        204      205       +1     
- Partials      125      126       +1     
Impacted Files Coverage Δ
src/pkgcheck/checks/codingstyle.py 96.44% <89.74%> (-0.53%) ⬇️
src/pkgcheck/checks/python.py 96.53% <0.00%> (-0.45%) ⬇️
src/pkgcheck/sources.py 86.69% <0.00%> (-0.32%) ⬇️
src/pkgcheck/checks/metadata_xml.py 96.44% <0.00%> (-0.26%) ⬇️
src/pkgcheck/checks/network.py 79.09% <0.00%> (-0.24%) ⬇️
src/pkgcheck/objects.py 100.00% <0.00%> (ø)
src/pkgcheck/results.py 85.93% <0.00%> (+0.07%) ⬆️
src/pkgcheck/checks/git.py 97.60% <0.00%> (+0.50%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c2761ba...078758a. Read the comment docs.

Comment thread src/pkgcheck/checks/codingstyle.py Outdated
@arthurzam
Copy link
Copy Markdown
Member

The implementation looks very good! Nice usage of tree-sitter-bash!
About the tests. In the #gentoo-portage talk, I saw a lot of good examples for various lines we can check. I would like to have a "hell ebuild" for the tests, that have a ton of various variables on various lines (some fine, some not), so when we change a little the implementation here, this ebuild could be a decision maker (is this line OK? then fix impl - now behavior changes to be as desired).

Comment thread src/pkgcheck/checks/codingstyle.py Outdated
Comment thread testdata/data/repos/standalone/UnquotedVariablesCheck/UnquotedVariable/fix.patch Outdated
Comment thread src/pkgcheck/checks/codingstyle.py Outdated
Comment thread src/pkgcheck/checks/codingstyle.py Outdated
Comment thread testdata/data/repos/standalone/UnquotedVariablesCheck/UnquotedVariable/fix.patch Outdated
Comment thread src/pkgcheck/checks/codingstyle.py Outdated
Comment thread src/pkgcheck/checks/codingstyle.py Outdated
Comment thread src/pkgcheck/checks/codingstyle.py Outdated
Comment thread src/pkgcheck/checks/codingstyle.py Outdated
Comment thread src/pkgcheck/checks/codingstyle.py Outdated
Comment thread src/pkgcheck/checks/codingstyle.py Outdated
@laumann
Copy link
Copy Markdown
Contributor Author

laumann commented May 19, 2022

Also @floppym if you're interested

@laumann
Copy link
Copy Markdown
Contributor Author

laumann commented May 19, 2022

For the record, here's the list of warnings currently produced by this check

Total: 457
app-accessibility/sound-icons
  UnquotedVariable: version 0.1: 25: Variable S should be quoted

app-admin/salt
  UnquotedVariable: version 3003-r1: 164: Variable TMPDIR should be quoted
  UnquotedVariable: version 3003-r1: 167: Variable TMPDIR should be quoted
  UnquotedVariable: version 3003.3: 171: Variable TMPDIR should be quoted
  UnquotedVariable: version 3003.3: 174: Variable TMPDIR should be quoted
  UnquotedVariable: version 3003.3-r1: 172: Variable TMPDIR should be quoted
  UnquotedVariable: version 3003.3-r1: 175: Variable TMPDIR should be quoted
  UnquotedVariable: version 3003.4-r1: 174: Variable TMPDIR should be quoted
  UnquotedVariable: version 3003.4-r1: 177: Variable TMPDIR should be quoted
  UnquotedVariable: version 3004.1-r4: 176: Variable TMPDIR should be quoted
  UnquotedVariable: version 3004.1-r4: 179: Variable TMPDIR should be quoted

app-antivirus/lkrg
  UnquotedVariable: version 0.9.2: 36: Variable DISTDIR should be quoted
  UnquotedVariable: version 0.9.3: 34: Variable DISTDIR should be quoted

app-arch/alien
  UnquotedVariable: version 8.95-r1: 32: Variable D should be quoted
  UnquotedVariable: version 8.95-r1: 32: Variable D should be quoted

app-arch/hardlink
  UnquotedVariable: version 0.3.2: 23: Variable T should be quoted

app-backup/tsm
  UnquotedVariable: version 8.1.13.3: 184: Variable D should be quoted
  UnquotedVariable: version 8.1.13.3: 185: Variable D should be quoted
  UnquotedVariable: version 8.1.13.3: 188: Variable D should be quoted
  UnquotedVariable: version 8.1.13.3: 189: Variable D should be quoted
  UnquotedVariable: version 8.1.13.3: 190: Variable D should be quoted

app-cdr/dvdisaster
  UnquotedVariable: version 0.79.5: 81: Variable ED should be quoted

app-containers/lxd
  UnquotedVariable: version 4.0.9-r3: 128: Variable S should be quoted

app-crypt/libsecret
  UnquotedVariable: version 0.20.5-r3: 75: Variable BROOT should be quoted

app-crypt/p11-kit
  UnquotedVariable: version 0.23.22: 47: Variable EPREFIX should be quoted
  UnquotedVariable: version 0.24.1: 47: Variable EPREFIX should be quoted

app-editors/qhexedit2
  UnquotedVariable: version 0.8.6_p20190316-r1: 71: Variable S should be quoted
  UnquotedVariable: version 0.8.6_p20190316-r1: 93: Variable S should be quoted
  UnquotedVariable: version 0.8.9_p20210525-r1: 73: Variable S should be quoted
  UnquotedVariable: version 0.8.9_p20210525-r1: 95: Variable S should be quoted

app-emulation/qemu
  UnquotedVariable: version 6.2.0: 872: Variable EROOT should be quoted
  UnquotedVariable: version 6.2.0-r3: 883: Variable EROOT should be quoted
  UnquotedVariable: version 6.2.0-r4: 884: Variable EROOT should be quoted
  UnquotedVariable: version 7.0.0_rc4: 873: Variable EROOT should be quoted
  UnquotedVariable: version 7.0.0-r1: 873: Variable EROOT should be quoted
  UnquotedVariable: version 9999: 871: Variable EROOT should be quoted

app-misc/mc
  UnquotedVariable: version 9999: 66: Variable S should be quoted

app-misc/tdl
  UnquotedVariable: version 1.5.2-r3: 44: Variable EPREFIX should be quoted

app-shells/bash
  UnquotedVariable: version 4.3_p48-r2: 120: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3_p48-r2: 120: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3_p48-r2: 120: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3_p48-r2: 120: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3_p48-r2: 120: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3_p48-r2: 120: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3_p48-r2: 121: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3_p48-r2: 121: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3_p48-r2: 121: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3_p48-r2: 121: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3_p48-r2: 122: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3_p48-r2: 123: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 129: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 129: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 129: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 129: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 129: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 129: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 130: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 130: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 130: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 130: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 131: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 132: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 133: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 133: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 133: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 133: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 133: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 133: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 134: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 134: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 134: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 134: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 135: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 136: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 140: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 140: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 140: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 140: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 140: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 140: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 141: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 141: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 141: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 141: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 142: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 143: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 154: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 154: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 154: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 154: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 155: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 156: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 154: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 154: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 154: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 154: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 155: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 156: Variable EPREFIX should be quoted

dev-db/myodbc
  UnquotedVariable: version 8.0.27-r1: 56: Variable EPREFIX should be quoted

dev-db/pgtap
  UnquotedVariable: version 1.2.0-r2: 36: Variable ED should be quoted

dev-embedded/libftd2xx
  UnquotedVariable: version 1.4.8: 34: Variable ED should be quoted

dev-haskell/language-haskell-extract
  UnquotedVariable: version 0.2.4-r1: 25: Variable FILESDIR should be quoted

dev-haskell/wcwidth
  UnquotedVariable: version 0.0.2: 29: Variable FILESDIR should be quoted

dev-java/openjfx
  UnquotedVariable: version 11.0.9_p0: 203: Variable T should be quoted
  UnquotedVariable: version 11.0.11_p1: 203: Variable T should be quoted

dev-lang/gforth
  UnquotedVariable: version 0.7.3-r2: 39: Variable EPREFIX should be quoted

dev-lang/mlton
  UnquotedVariable: version 20180207: 91: Variable S should be quoted

dev-lang/lua
  UnquotedVariable: version 5.1.5-r106: 80: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1.5-r107: 85: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.3.6-r2: 71: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.3.6-r3: 76: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.4.2-r1: 67: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.4.2-r2: 72: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.4.4: 72: Variable EPREFIX should be quoted

dev-lang/rust-bin
  UnquotedVariable: version 1.58.1: 108: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.59.0: 108: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.60.0: 113: Variable EPREFIX should be quoted

dev-lang/teyjus
  UnquotedVariable: version 2.1: 86: Variable EPREFIX should be quoted
  UnquotedVariable: version 2.1-r1: 88: Variable EPREFIX should be quoted

dev-lang/spidermonkey
  UnquotedVariable: version 1.8.5-r10: 54: Variable S should be quoted

dev-libs/libpwquality
  UnquotedVariable: version 1.4.4: 34: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.4.4-r1: 33: Variable EPREFIX should be quoted

dev-libs/openssl-compat
  UnquotedVariable: version 1.0.2u-r2: 135: Variable EPREFIX should be quoted

dev-libs/openssl
  UnquotedVariable: version 1.0.2u-r1: 128: Variable EPREFIX should be quoted

dev-perl/Net-Subnet
  UnquotedVariable: version 1.30.0-r2: 20: Variable FILESDIR should be quoted

dev-perl/Tk
  UnquotedVariable: version 804.36.0: 33: Variable EPREFIX should be quoted
  UnquotedVariable: version 804.36.0: 33: Variable EPREFIX should be quoted
  UnquotedVariable: version 804.36.0: 33: Variable EPREFIX should be quoted

dev-php/PEAR-PEAR
  UnquotedVariable: version 1.10.12: 118: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.10.12: 122: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.10.12: 126: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.10.12: 130: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.10.12: 134: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.10.13: 118: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.10.13: 122: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.10.13: 126: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.10.13: 130: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.10.13: 134: Variable EPREFIX should be quoted

dev-python/pywavelets
  UnquotedVariable: version 1.1.1: 37: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 1.2.0: 36: Variable BUILD_DIR should be quoted

dev-python/shiboken2
  UnquotedVariable: version 5.15.2-r1: 80: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.15.2-r1: 99: Variable EPREFIX should be quoted

dev-python/tpm2-pytss
  UnquotedVariable: version 1.1.0: 37: Variable T should be quoted
  UnquotedVariable: version 1.1.0: 39: Variable S should be quoted

dev-ruby/hiera-eyaml
  UnquotedVariable: version 3.1.1: 34: Variable T should be quoted
  UnquotedVariable: version 3.1.1: 42: Variable S should be quoted
  UnquotedVariable: version 3.2.2: 34: Variable T should be quoted
  UnquotedVariable: version 3.2.2: 43: Variable S should be quoted

dev-ruby/hiredis
  UnquotedVariable: version 0.6.3-r1: 36: Variable T should be quoted

dev-ruby/ruby-mp3info
  UnquotedVariable: version 0.8.10-r1: 27: Variable T should be quoted

dev-ruby/rubyzip
  UnquotedVariable: version 1.3.0: 45: Variable T should be quoted
  UnquotedVariable: version 2.3.2-r1: 47: Variable T should be quoted

dev-ruby/sassc
  UnquotedVariable: version 2.4.0-r1: 37: Variable ESYSROOT should be quoted

dev-scheme/kawa
  UnquotedVariable: version 1.14-r2: 71: Variable WORKDIR should be quoted

dev-util/nvidia-cuda-toolkit
  UnquotedVariable: version 11.5.1-r1: 224: Variable EROOT should be quoted
  UnquotedVariable: version 11.6.0: 235: Variable EROOT should be quoted
  UnquotedVariable: version 11.6.1: 235: Variable EROOT should be quoted
  UnquotedVariable: version 11.6.2: 235: Variable EROOT should be quoted

dev-vcs/cvs
  UnquotedVariable: version 1.12.12-r14: 68: Variable EPREFIX should be quoted

dev-vcs/subversion
  UnquotedVariable: version 1.14.1: 93: Variable EPREFIX should be quoted

games-action/nighthawk
  UnquotedVariable: version 4.0: 48: Variable ED should be quoted

games-emulation/mgba
  UnquotedVariable: version 0.9.2: 97: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 0.9.2: 106: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 0.9.2: 109: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 0.9.3: 97: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 0.9.3: 106: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 0.9.3: 109: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 0.9.3-r1: 101: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 0.9.3-r1: 110: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 0.9.3-r1: 113: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 9999: 97: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 9999: 106: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 9999: 109: Variable BUILD_DIR should be quoted

gnome-base/gdm
  UnquotedVariable: version 41.3: 204: Variable EROOT should be quoted
  UnquotedVariable: version 42.0: 199: Variable EROOT should be quoted

gnome-base/gnome-desktop
  UnquotedVariable: version 42.0-r300: 80: Variable ED should be quoted
  UnquotedVariable: version 42.0-r300: 81: Variable ED should be quoted
  UnquotedVariable: version 42.1-r300: 77: Variable ED should be quoted
  UnquotedVariable: version 42.1-r300: 78: Variable ED should be quoted

gnustep-base/gnustep-make
  UnquotedVariable: version 2.8.0: 56: Variable EPREFIX should be quoted
  UnquotedVariable: version 2.9.0: 56: Variable EPREFIX should be quoted

gnustep-libs/dbuskit
  UnquotedVariable: version 0.1.1-r1: 19: Variable FILESDIR should be quoted

mail-client/neomutt
  UnquotedVariable: version 20210205-r1: 123: Variable S should be quoted
  UnquotedVariable: version 20211015: 119: Variable S should be quoted
  UnquotedVariable: version 20211022: 119: Variable S should be quoted
  UnquotedVariable: version 20211029: 119: Variable S should be quoted
  UnquotedVariable: version 20211029-r1: 128: Variable S should be quoted
  UnquotedVariable: version 20220408: 128: Variable S should be quoted
  UnquotedVariable: version 20220415: 128: Variable S should be quoted
  UnquotedVariable: version 20220429: 128: Variable S should be quoted
  UnquotedVariable: version 99999999: 128: Variable S should be quoted

media-fonts/monafont
  UnquotedVariable: version 2.90-r2: 55: Variable WORKDIR should be quoted

media-gfx/blender
  UnquotedVariable: version 2.93.0-r1: 309: Variable ED should be quoted
  UnquotedVariable: version 2.93.6: 283: Variable ED should be quoted
  UnquotedVariable: version 2.93.8-r4: 299: Variable ED should be quoted
  UnquotedVariable: version 2.93.8-r5: 302: Variable ED should be quoted
  UnquotedVariable: version 3.0.0-r1: 304: Variable ED should be quoted
  UnquotedVariable: version 3.0.1-r4: 307: Variable ED should be quoted
  UnquotedVariable: version 3.0.1-r5: 310: Variable ED should be quoted
  UnquotedVariable: version 3.1.0: 301: Variable ED should be quoted
  UnquotedVariable: version 3.1.1: 301: Variable ED should be quoted
  UnquotedVariable: version 3.1.2: 302: Variable ED should be quoted
  UnquotedVariable: version 9999: 301: Variable ED should be quoted

media-gfx/povray
  UnquotedVariable: version 3.7.0.0-r1: 76: Variable EPREFIX should be quoted
  UnquotedVariable: version 3.7.0.0-r1: 77: Variable EPREFIX should be quoted
  UnquotedVariable: version 3.7.0.0-r1: 105: Variable EROOT should be quoted
  UnquotedVariable: version 3.7.0.0-r1: 105: Variable EROOT should be quoted
  UnquotedVariable: version 3.7.0.0-r2: 73: Variable EPREFIX should be quoted
  UnquotedVariable: version 3.7.0.0-r2: 74: Variable EPREFIX should be quoted
  UnquotedVariable: version 3.7.0.0-r2: 102: Variable EROOT should be quoted
  UnquotedVariable: version 3.7.0.0-r2: 102: Variable EROOT should be quoted

media-gfx/tuxpaint
  UnquotedVariable: version 0.9.27: 39: Variable FILESDIR should be quoted

media-libs/libvmaf
  UnquotedVariable: version 2.3.0-r2: 41: Variable S should be quoted

media-libs/sdl2-mixer
  UnquotedVariable: version 2.0.4: 94: Variable EPREFIX should be quoted
  UnquotedVariable: version 2.0.4-r1: 95: Variable EPREFIX should be quoted

media-libs/woff2
  UnquotedVariable: version 1.0.2-r5: 32: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 1.0.2-r5: 33: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 1.0.2-r5: 34: Variable BUILD_DIR should be quoted

media-sound/mixxx
  UnquotedVariable: version 2.3.2: 154: Variable DISTDIR should be quoted
  UnquotedVariable: version 2.3.9999: 152: Variable DISTDIR should be quoted

media-video/vdr
  UnquotedVariable: version 2.2.0-r6: 77: Variable T should be quoted
  UnquotedVariable: version 2.2.0-r6: 97: Variable S should be quoted
  UnquotedVariable: version 2.2.0-r7: 77: Variable T should be quoted
  UnquotedVariable: version 2.2.0-r7: 97: Variable S should be quoted
  UnquotedVariable: version 2.4.7-r1: 68: Variable S should be quoted

media-video/wireplumber
  UnquotedVariable: version 0.4.9: 89: Variable ED should be quoted
  UnquotedVariable: version 0.4.9-r1: 94: Variable ED should be quoted
  UnquotedVariable: version 0.4.10: 91: Variable ED should be quoted
  UnquotedVariable: version 0.4.10-r1: 95: Variable ED should be quoted
  UnquotedVariable: version 9999: 91: Variable ED should be quoted

net-analyzer/ipguard
  UnquotedVariable: version 1.04-r1: 34: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.04-r1: 41: Variable EPREFIX should be quoted

net-ftp/lftp
  UnquotedVariable: version 4.9.2: 79: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 77: Variable EPREFIX should be quoted

net-irc/znc-clientbuffer
  UnquotedVariable: version 1.0.48: 24: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.0.48: 34: Variable ED should be quoted

net-mail/automx2
  UnquotedVariable: version 2021.6: 39: Variable S should be quoted
  UnquotedVariable: version 2021.6: 39: Variable S should be quoted
  UnquotedVariable: version 2021.6: 40: Variable S should be quoted
  UnquotedVariable: version 2022.0: 38: Variable S should be quoted
  UnquotedVariable: version 2022.0: 38: Variable S should be quoted
  UnquotedVariable: version 2022.0: 39: Variable S should be quoted

net-mail/relay-ctrl
  UnquotedVariable: version 3.1.1-r2: 55: Variable D should be quoted
  UnquotedVariable: version 3.1.1-r2: 57: Variable D should be quoted
  UnquotedVariable: version 3.1.1-r3: 57: Variable D should be quoted
  UnquotedVariable: version 3.1.1-r3: 59: Variable D should be quoted
  UnquotedVariable: version 3.1.1-r3: 62: Variable D should be quoted
  UnquotedVariable: version 3.2: 58: Variable D should be quoted
  UnquotedVariable: version 3.2: 60: Variable D should be quoted
  UnquotedVariable: version 3.2: 63: Variable D should be quoted

net-misc/openssh
  UnquotedVariable: version 8.9_p1-r2: 114: Variable EROOT should be quoted
  UnquotedVariable: version 8.9_p1-r2: 122: Variable DISTDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 127: Variable EPREFIX should be quoted
  UnquotedVariable: version 8.9_p1-r2: 133: Variable FILESDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 134: Variable FILESDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 135: Variable FILESDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 136: Variable FILESDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 137: Variable FILESDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 138: Variable FILESDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 139: Variable FILESDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 140: Variable FILESDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 141: Variable FILESDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 143: Variable WORKDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 148: Variable WORKDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 149: Variable FILESDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 152: Variable WORKDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 160: Variable S should be quoted
  UnquotedVariable: version 9.0_p1: 114: Variable EROOT should be quoted
  UnquotedVariable: version 9.0_p1: 122: Variable DISTDIR should be quoted
  UnquotedVariable: version 9.0_p1: 127: Variable EPREFIX should be quoted
  UnquotedVariable: version 9.0_p1: 133: Variable FILESDIR should be quoted
  UnquotedVariable: version 9.0_p1: 134: Variable FILESDIR should be quoted
  UnquotedVariable: version 9.0_p1: 135: Variable FILESDIR should be quoted
  UnquotedVariable: version 9.0_p1: 136: Variable FILESDIR should be quoted
  UnquotedVariable: version 9.0_p1: 137: Variable FILESDIR should be quoted
  UnquotedVariable: version 9.0_p1: 138: Variable FILESDIR should be quoted
  UnquotedVariable: version 9.0_p1: 139: Variable FILESDIR should be quoted
  UnquotedVariable: version 9.0_p1: 140: Variable FILESDIR should be quoted
  UnquotedVariable: version 9.0_p1: 142: Variable WORKDIR should be quoted
  UnquotedVariable: version 9.0_p1: 147: Variable WORKDIR should be quoted
  UnquotedVariable: version 9.0_p1: 148: Variable FILESDIR should be quoted
  UnquotedVariable: version 9.0_p1: 151: Variable WORKDIR should be quoted
  UnquotedVariable: version 9.0_p1: 159: Variable S should be quoted

net-print/cnijfilter2
  UnquotedVariable: version 5.90: 69: Variable S should be quoted

net-proxy/haproxy
  UnquotedVariable: version 2.4.14: 102: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.4.14: 103: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.4.14: 108: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.4.14: 110: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.4.17: 100: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.4.17: 101: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.4.17: 106: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.4.17: 108: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.4.9999: 100: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.4.9999: 101: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.4.9999: 106: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.4.9999: 108: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.4: 102: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.4: 103: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.4: 108: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.4: 110: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.7: 100: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.7: 101: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.7: 106: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.7: 108: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.9999: 100: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.9999: 101: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.9999: 106: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.9999: 108: Variable ESYSROOT should be quoted
  UnquotedVariable: version 9999: 100: Variable ESYSROOT should be quoted
  UnquotedVariable: version 9999: 101: Variable ESYSROOT should be quoted
  UnquotedVariable: version 9999: 106: Variable ESYSROOT should be quoted
  UnquotedVariable: version 9999: 108: Variable ESYSROOT should be quoted

net-wireless/crackle
  UnquotedVariable: version 0.1-r1: 22: Variable FILESDIR should be quoted

net-wireless/iwd
  UnquotedVariable: version 1.26: 180: Variable ED should be quoted
  UnquotedVariable: version 1.27: 180: Variable ED should be quoted
  UnquotedVariable: version 9999: 180: Variable ED should be quoted

sci-astronomy/pyephem
  UnquotedVariable: version 3.7.7.1: 37: Variable BUILD_DIR should be quoted

sci-biology/consed
  UnquotedVariable: version 29: 58: Variable EPREFIX should be quoted

sci-biology/hmmer
  UnquotedVariable: version 2.3.2-r4: 27: Variable TMPDIR should be quoted

sci-chemistry/molequeue
  UnquotedVariable: version 0.9.0-r1: 56: Variable EPREFIX should be quoted

sci-chemistry/gromacs
  UnquotedVariable: version 2020.4-r1: 139: Variable HOME should be quoted
  UnquotedVariable: version 2020.4-r1: 140: Variable HOME should be quoted
  UnquotedVariable: version 2020.7: 139: Variable HOME should be quoted
  UnquotedVariable: version 2020.7: 140: Variable HOME should be quoted
  UnquotedVariable: version 2021.3-r1: 139: Variable HOME should be quoted
  UnquotedVariable: version 2021.3-r1: 140: Variable HOME should be quoted
  UnquotedVariable: version 2021.5: 139: Variable HOME should be quoted
  UnquotedVariable: version 2021.5: 140: Variable HOME should be quoted
  UnquotedVariable: version 2021.9999: 137: Variable HOME should be quoted
  UnquotedVariable: version 2021.9999: 138: Variable HOME should be quoted
  UnquotedVariable: version 2022: 149: Variable HOME should be quoted
  UnquotedVariable: version 2022: 150: Variable HOME should be quoted
  UnquotedVariable: version 2022.1: 149: Variable HOME should be quoted
  UnquotedVariable: version 2022.1: 150: Variable HOME should be quoted
  UnquotedVariable: version 2022.9999: 134: Variable HOME should be quoted
  UnquotedVariable: version 2022.9999: 135: Variable HOME should be quoted
  UnquotedVariable: version 9999: 134: Variable HOME should be quoted
  UnquotedVariable: version 9999: 135: Variable HOME should be quoted

sci-libs/libsc
  UnquotedVariable: version 2.3.1-r1: 58: Variable S should be quoted
  UnquotedVariable: version 2.3.3: 58: Variable S should be quoted

sci-libs/p4est
  UnquotedVariable: version 2.3.1-r1: 66: Variable S should be quoted
  UnquotedVariable: version 2.3.3: 66: Variable S should be quoted

sec-keys/openpgp-keys-voikko
  UnquotedVariable: version 20201013: 18: Variable DISTDIR should be quoted

sec-policy/selinux-base-policy
  UnquotedVariable: version 2.20220106-r1: 60: Variable S should be quoted
  UnquotedVariable: version 2.20220106-r1: 61: Variable S should be quoted
  UnquotedVariable: version 2.20220106-r2: 60: Variable S should be quoted
  UnquotedVariable: version 2.20220106-r2: 61: Variable S should be quoted
  UnquotedVariable: version 2.20220106-r3: 60: Variable S should be quoted
  UnquotedVariable: version 2.20220106-r3: 61: Variable S should be quoted
  UnquotedVariable: version 9999: 60: Variable S should be quoted
  UnquotedVariable: version 9999: 61: Variable S should be quoted

sys-apps/nvme-cli
  UnquotedVariable: version 2.0: 31: Variable EPREFIX should be quoted

sys-auth/elogind
  UnquotedVariable: version 246.10-r1: 69: Variable EPREFIX should be quoted

sys-auth/libfprint
  UnquotedVariable: version 1.0: 30: Variable FILESDIR should be quoted

sys-block/flashbench
  UnquotedVariable: version 20120606: 13: Variable FILESDIR should be quoted

sys-block/open-iscsi
  UnquotedVariable: version 2.1.4-r2: 136: Variable ROOT should be quoted
  UnquotedVariable: version 2.1.6-r1: 129: Variable ROOT should be quoted

sys-boot/milo
  UnquotedVariable: version 2.4.18: 96: Variable WORKDIR should be quoted
  UnquotedVariable: version 2.4.18: 97: Variable WORKDIR should be quoted
  UnquotedVariable: version 2.4.18: 98: Variable S should be quoted
  UnquotedVariable: version 2.4.18: 141: Variable S should be quoted
  UnquotedVariable: version 2.4.18: 157: Variable S should be quoted
  UnquotedVariable: version 2.4.18: 158: Variable WORKDIR should be quoted
  UnquotedVariable: version 2.4.18: 159: Variable WORKDIR should be quoted
  UnquotedVariable: version 2.4.18: 168: Variable WORKDIR should be quoted
  UnquotedVariable: version 2.4.18: 176: Variable FILESDIR should be quoted
  UnquotedVariable: version 2.4.18: 176: Variable WORKDIR should be quoted
  UnquotedVariable: version 2.4.18: 179: Variable WORKDIR should be quoted
  UnquotedVariable: version 2.4.18: 180: Variable WORKDIR should be quoted
  UnquotedVariable: version 2.4.18: 194: Variable S should be quoted
  UnquotedVariable: version 2.4.18: 197: Variable S should be quoted
  UnquotedVariable: version 2.4.18: 200: Variable DISTDIR should be quoted
  UnquotedVariable: version 2.4.18: 200: Variable S should be quoted
  UnquotedVariable: version 2.4.18: 201: Variable DISTDIR should be quoted
  UnquotedVariable: version 2.4.18: 201: Variable S should be quoted
  UnquotedVariable: version 2.4.18: 207: Variable S should be quoted
  UnquotedVariable: version 2.4.18: 217: Variable S should be quoted
  UnquotedVariable: version 2.4.18: 220: Variable DISTDIR should be quoted
  UnquotedVariable: version 2.4.18: 220: Variable FILESDIR should be quoted
  UnquotedVariable: version 2.4.18: 220: Variable FILESDIR should be quoted

sys-cluster/c3
  UnquotedVariable: version 4.0.1: 41: Variable D should be quoted
  UnquotedVariable: version 4.0.1: 42: Variable D should be quoted

sys-cluster/sanlock
  UnquotedVariable: version 3.8.2: 30: Variable FILESDIR should be quoted

sys-devel/binutils-apple
  UnquotedVariable: version 3.2.6: 203: Variable D should be quoted
  UnquotedVariable: version 3.2.6: 204: Variable EPREFIX should be quoted
  UnquotedVariable: version 3.2.6: 205: Variable EPREFIX should be quoted
  UnquotedVariable: version 3.2.6: 206: Variable EPREFIX should be quoted
  UnquotedVariable: version 3.2.6: 207: Variable EPREFIX should be quoted
  UnquotedVariable: version 3.2.6: 208: Variable EPREFIX should be quoted
  UnquotedVariable: version 3.2.6: 212: Variable D should be quoted
  UnquotedVariable: version 3.2.6: 213: Variable EPREFIX should be quoted
  UnquotedVariable: version 3.2.6: 214: Variable EPREFIX should be quoted
  UnquotedVariable: version 3.2.6: 215: Variable EPREFIX should be quoted
  UnquotedVariable: version 8.2.1-r1: 266: Variable D should be quoted
  UnquotedVariable: version 8.2.1-r1: 267: Variable EPREFIX should be quoted
  UnquotedVariable: version 8.2.1-r1: 268: Variable EPREFIX should be quoted
  UnquotedVariable: version 8.2.1-r1: 269: Variable EPREFIX should be quoted
  UnquotedVariable: version 8.2.1-r1: 270: Variable EPREFIX should be quoted
  UnquotedVariable: version 8.2.1-r1: 271: Variable EPREFIX should be quoted
  UnquotedVariable: version 8.2.1-r1: 275: Variable D should be quoted
  UnquotedVariable: version 8.2.1-r1: 276: Variable EPREFIX should be quoted
  UnquotedVariable: version 8.2.1-r1: 277: Variable EPREFIX should be quoted
  UnquotedVariable: version 8.2.1-r1: 278: Variable EPREFIX should be quoted

sys-devel/gcc-apple
  UnquotedVariable: version 4.2.1_p5666-r3: 320: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.2.1_p5666-r3: 322: Variable EPREFIX should be quoted

sys-devel/llvm-roc
  UnquotedVariable: version 4.0.0: 41: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.0.0-r2: 42: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.0.1: 42: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.1.0: 42: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.1.1: 42: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.2.0: 42: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3.0-r1: 43: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.5.2: 43: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0.2: 43: Variable EPREFIX should be quoted

sys-libs/compiler-rt
  UnquotedVariable: version 12.0.1: 100: Variable EPREFIX should be quoted
  UnquotedVariable: version 13.0.1: 113: Variable EPREFIX should be quoted
  UnquotedVariable: version 14.0.1: 113: Variable EPREFIX should be quoted
  UnquotedVariable: version 14.0.3: 115: Variable EPREFIX should be quoted
  UnquotedVariable: version 15.0.0.9999: 115: Variable EPREFIX should be quoted

sys-libs/compiler-rt-sanitizers
  UnquotedVariable: version 12.0.1: 162: Variable EPREFIX should be quoted
  UnquotedVariable: version 13.0.1: 176: Variable EPREFIX should be quoted
  UnquotedVariable: version 14.0.1: 176: Variable EPREFIX should be quoted
  UnquotedVariable: version 14.0.3: 182: Variable EPREFIX should be quoted
  UnquotedVariable: version 15.0.0.9999: 182: Variable EPREFIX should be quoted

sys-libs/musl
  UnquotedVariable: version 1.2.2-r8: 99: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.2.2-r8: 100: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.2.2-r8: 132: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.2.3: 99: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.2.3: 100: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.2.3: 132: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 99: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 100: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 132: Variable EPREFIX should be quoted

www-apps/miniflux
  UnquotedVariable: version 2.0.36: 91: Variable EROOT should be quoted

www-apps/nanoc-core
  UnquotedVariable: version 4.11.12: 60: Variable T should be quoted
  UnquotedVariable: version 4.12.2: 66: Variable T should be quoted
  UnquotedVariable: version 4.12.3: 66: Variable T should be quoted
  UnquotedVariable: version 4.12.5: 66: Variable T should be quoted

www-client/seamonkey
  UnquotedVariable: version 2.53.10.2: 525: Variable T should be quoted
  UnquotedVariable: version 2.53.11: 520: Variable T should be quoted
  UnquotedVariable: version 2.53.11-r1: 520: Variable T should be quoted
  UnquotedVariable: version 2.53.11.1: 510: Variable T should be quoted
  UnquotedVariable: version 2.53.12: 541: Variable T should be quoted

www-plugins/browserpass
  UnquotedVariable: version 3.0.9: 25: Variable EPREFIX should be quoted

x11-plugins/wmwork
  UnquotedVariable: version 0.2.5-r1: 23: Variable FILESDIR should be quoted

@laumann
Copy link
Copy Markdown
Contributor Author

laumann commented May 19, 2022

One thing that concerns me is the warnings produced for net-misc/openssh:

net-misc/openssh
  UnquotedVariable: version 8.9_p1-r2: 114: Variable EROOT should be quoted
  UnquotedVariable: version 8.9_p1-r2: 122: Variable DISTDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 127: Variable EPREFIX should be quoted
  UnquotedVariable: version 8.9_p1-r2: 133: Variable FILESDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 134: Variable FILESDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 135: Variable FILESDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 136: Variable FILESDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 137: Variable FILESDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 138: Variable FILESDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 139: Variable FILESDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 140: Variable FILESDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 141: Variable FILESDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 143: Variable WORKDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 148: Variable WORKDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 149: Variable FILESDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 152: Variable WORKDIR should be quoted
  UnquotedVariable: version 8.9_p1-r2: 160: Variable S should be quoted
  UnquotedVariable: version 9.0_p1: 114: Variable EROOT should be quoted
  UnquotedVariable: version 9.0_p1: 122: Variable DISTDIR should be quoted
  UnquotedVariable: version 9.0_p1: 127: Variable EPREFIX should be quoted
  UnquotedVariable: version 9.0_p1: 133: Variable FILESDIR should be quoted
  UnquotedVariable: version 9.0_p1: 134: Variable FILESDIR should be quoted
  UnquotedVariable: version 9.0_p1: 135: Variable FILESDIR should be quoted
  UnquotedVariable: version 9.0_p1: 136: Variable FILESDIR should be quoted
  UnquotedVariable: version 9.0_p1: 137: Variable FILESDIR should be quoted
  UnquotedVariable: version 9.0_p1: 138: Variable FILESDIR should be quoted
  UnquotedVariable: version 9.0_p1: 139: Variable FILESDIR should be quoted
  UnquotedVariable: version 9.0_p1: 140: Variable FILESDIR should be quoted
  UnquotedVariable: version 9.0_p1: 142: Variable WORKDIR should be quoted
  UnquotedVariable: version 9.0_p1: 147: Variable WORKDIR should be quoted
  UnquotedVariable: version 9.0_p1: 148: Variable FILESDIR should be quoted
  UnquotedVariable: version 9.0_p1: 151: Variable WORKDIR should be quoted
  UnquotedVariable: version 9.0_p1: 159: Variable S should be quoted

These all appear to be false positives - but I haven't yet figured out how to address these.

EDIT: I have a strong suspicion that the openssh ebuilds aren't parsed properly by tree-sitter-bash.

@floppym
Copy link
Copy Markdown
Contributor

floppym commented May 20, 2022

EDIT: I have a strong suspicion that the openssh ebuilds aren't parsed properly by tree-sitter-bash.

Yeah, it looks like it gets confused by this line:

https://github.com/gentoo/gentoo/blob/4cf2bc6a0622fb751152814049fea2f9805f6f8d/net-misc/openssh/openssh-9.0_p1-r1.ebuild#L114

Removing that line from the ebuild makes the false positives go away.

Comment thread src/pkgcheck/checks/codingstyle.py Outdated
@arthurzam
Copy link
Copy Markdown
Member

arthurzam commented May 20, 2022

EDIT: I have a strong suspicion that the openssh ebuilds aren't parsed properly by tree-sitter-bash.

Yeah, it looks like it gets confused by this line:

https://github.com/gentoo/gentoo/blob/4cf2bc6a0622fb751152814049fea2f9805f6f8d/net-misc/openssh/openssh-9.0_p1-r1.ebuild#L114

Removing that line from the ebuild makes the false positives go away.

Some more investigating, and the following 2 lines [1] are very confusing tree-sitter (21 children for root instead of 81). If I break those 2 lines into 4 lines of assignment, everything works correctly.

[1] https://github.com/gentoo/gentoo/blob/4cf2bc6a0622fb751152814049fea2f9805f6f8d/net-misc/openssh/openssh-9.0_p1-r1.ebuild#L23-L24

EDIT: fixed in gentoo/gentoo@de045c1

@laumann
Copy link
Copy Markdown
Contributor Author

laumann commented May 20, 2022

Thanks @arthurzam @floppym for helping me hunt down the false positives. It's pretty clear the root cause for net-misc/openssh is a bug in the tree-sitter-bash parser, I've opened an issue detailing where the parser goes wrong: tree-sitter/tree-sitter-bash#122

@laumann
Copy link
Copy Markdown
Contributor Author

laumann commented May 20, 2022

but it gave me an idea: if the parser has an ERROR node in the tree, maybe we should just skip this check to avoid potential false positives?

@laumann
Copy link
Copy Markdown
Contributor Author

laumann commented May 21, 2022

Just an update: now ebuilds that tree-sitter-bash doesn't parse correctly are skipped for this check to avoid false positives. That results in the current report:

Total: 383
app-accessibility/sound-icons
  UnquotedVariable: version 0.1: 25: Variable S should be quoted

app-admin/salt
  UnquotedVariable: version 3003-r1: 164: Variable TMPDIR should be quoted
  UnquotedVariable: version 3003-r1: 167: Variable TMPDIR should be quoted
  UnquotedVariable: version 3003.3: 171: Variable TMPDIR should be quoted
  UnquotedVariable: version 3003.3: 174: Variable TMPDIR should be quoted
  UnquotedVariable: version 3003.3-r1: 172: Variable TMPDIR should be quoted
  UnquotedVariable: version 3003.3-r1: 175: Variable TMPDIR should be quoted
  UnquotedVariable: version 3003.4-r1: 174: Variable TMPDIR should be quoted
  UnquotedVariable: version 3003.4-r1: 177: Variable TMPDIR should be quoted
  UnquotedVariable: version 3004.1-r4: 176: Variable TMPDIR should be quoted
  UnquotedVariable: version 3004.1-r4: 179: Variable TMPDIR should be quoted

app-antivirus/lkrg
  UnquotedVariable: version 0.9.2: 36: Variable DISTDIR should be quoted
  UnquotedVariable: version 0.9.3: 34: Variable DISTDIR should be quoted

app-arch/alien
  UnquotedVariable: version 8.95-r1: 32: Variable D should be quoted
  UnquotedVariable: version 8.95-r1: 32: Variable D should be quoted

app-backup/tsm
  UnquotedVariable: version 8.1.13.3: 184: Variable D should be quoted
  UnquotedVariable: version 8.1.13.3: 185: Variable D should be quoted
  UnquotedVariable: version 8.1.13.3: 188: Variable D should be quoted
  UnquotedVariable: version 8.1.13.3: 189: Variable D should be quoted
  UnquotedVariable: version 8.1.13.3: 190: Variable D should be quoted

app-cdr/dvdisaster
  UnquotedVariable: version 0.79.5: 81: Variable ED should be quoted

app-containers/lxd
  UnquotedVariable: version 4.0.9-r3: 128: Variable S should be quoted

app-crypt/libsecret
  UnquotedVariable: version 0.20.5-r3: 75: Variable BROOT should be quoted

app-crypt/p11-kit
  UnquotedVariable: version 0.23.22: 47: Variable EPREFIX should be quoted
  UnquotedVariable: version 0.24.1: 47: Variable EPREFIX should be quoted

app-editors/qhexedit2
  UnquotedVariable: version 0.8.6_p20190316-r1: 71: Variable S should be quoted
  UnquotedVariable: version 0.8.6_p20190316-r1: 93: Variable S should be quoted
  UnquotedVariable: version 0.8.9_p20210525-r1: 73: Variable S should be quoted
  UnquotedVariable: version 0.8.9_p20210525-r1: 95: Variable S should be quoted

app-misc/mc
  UnquotedVariable: version 9999: 66: Variable S should be quoted

app-misc/tdl
  UnquotedVariable: version 1.5.2-r3: 44: Variable EPREFIX should be quoted

app-shells/bash
  UnquotedVariable: version 4.3_p48-r2: 120: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3_p48-r2: 120: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3_p48-r2: 120: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3_p48-r2: 120: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3_p48-r2: 120: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3_p48-r2: 120: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3_p48-r2: 121: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3_p48-r2: 121: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3_p48-r2: 121: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3_p48-r2: 121: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3_p48-r2: 122: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3_p48-r2: 123: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 129: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 129: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 129: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 129: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 129: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 129: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 130: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 130: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 130: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 130: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 131: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.4_p23-r2: 132: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 133: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 133: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 133: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 133: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 133: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 133: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 134: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 134: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 134: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 134: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 135: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0_p18: 136: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 140: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 140: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 140: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 140: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 140: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 140: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 141: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 141: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 141: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 141: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 142: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1_p16: 143: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 154: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 154: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 154: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 154: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 155: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.2_beta: 156: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 153: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 154: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 154: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 154: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 154: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 155: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 156: Variable EPREFIX should be quoted

dev-db/myodbc
  UnquotedVariable: version 8.0.27-r1: 56: Variable EPREFIX should be quoted

dev-db/pgtap
  UnquotedVariable: version 1.2.0-r2: 36: Variable ED should be quoted

dev-embedded/libftd2xx
  UnquotedVariable: version 1.4.8: 34: Variable ED should be quoted

dev-haskell/language-haskell-extract
  UnquotedVariable: version 0.2.4-r1: 25: Variable FILESDIR should be quoted

dev-haskell/wcwidth
  UnquotedVariable: version 0.0.2: 29: Variable FILESDIR should be quoted

dev-lang/gforth
  UnquotedVariable: version 0.7.3-r2: 39: Variable EPREFIX should be quoted

dev-lang/mlton
  UnquotedVariable: version 20180207: 91: Variable S should be quoted

dev-lang/lua
  UnquotedVariable: version 5.1.5-r106: 80: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.1.5-r107: 85: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.3.6-r2: 71: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.3.6-r3: 76: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.4.2-r1: 67: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.4.2-r2: 72: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.4.4: 72: Variable EPREFIX should be quoted

dev-lang/teyjus
  UnquotedVariable: version 2.1: 86: Variable EPREFIX should be quoted
  UnquotedVariable: version 2.1-r1: 88: Variable EPREFIX should be quoted

dev-lang/spidermonkey
  UnquotedVariable: version 1.8.5-r10: 54: Variable S should be quoted

dev-libs/libpwquality
  UnquotedVariable: version 1.4.4: 34: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.4.4-r1: 33: Variable EPREFIX should be quoted

dev-perl/Net-Subnet
  UnquotedVariable: version 1.30.0-r2: 20: Variable FILESDIR should be quoted

dev-perl/Tk
  UnquotedVariable: version 804.36.0: 33: Variable EPREFIX should be quoted
  UnquotedVariable: version 804.36.0: 33: Variable EPREFIX should be quoted
  UnquotedVariable: version 804.36.0: 33: Variable EPREFIX should be quoted

dev-php/PEAR-PEAR
  UnquotedVariable: version 1.10.12: 118: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.10.12: 122: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.10.12: 126: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.10.12: 130: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.10.12: 134: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.10.13: 118: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.10.13: 122: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.10.13: 126: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.10.13: 130: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.10.13: 134: Variable EPREFIX should be quoted

dev-python/shiboken2
  UnquotedVariable: version 5.15.2-r1: 80: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.15.2-r1: 99: Variable EPREFIX should be quoted

dev-python/tpm2-pytss
  UnquotedVariable: version 1.1.0: 37: Variable T should be quoted
  UnquotedVariable: version 1.1.0: 39: Variable S should be quoted

dev-ruby/hiera-eyaml
  UnquotedVariable: version 3.1.1: 34: Variable T should be quoted
  UnquotedVariable: version 3.1.1: 42: Variable S should be quoted
  UnquotedVariable: version 3.2.2: 34: Variable T should be quoted
  UnquotedVariable: version 3.2.2: 43: Variable S should be quoted

dev-ruby/hiredis
  UnquotedVariable: version 0.6.3-r1: 36: Variable T should be quoted

dev-ruby/ruby-mp3info
  UnquotedVariable: version 0.8.10-r1: 27: Variable T should be quoted

dev-ruby/rubyzip
  UnquotedVariable: version 1.3.0: 45: Variable T should be quoted
  UnquotedVariable: version 2.3.2-r1: 47: Variable T should be quoted

dev-ruby/sassc
  UnquotedVariable: version 2.4.0-r1: 37: Variable ESYSROOT should be quoted

dev-scheme/kawa
  UnquotedVariable: version 1.14-r2: 71: Variable WORKDIR should be quoted

dev-util/nvidia-cuda-toolkit
  UnquotedVariable: version 11.5.1-r1: 224: Variable EROOT should be quoted
  UnquotedVariable: version 11.6.0: 235: Variable EROOT should be quoted
  UnquotedVariable: version 11.6.1: 235: Variable EROOT should be quoted
  UnquotedVariable: version 11.6.2: 235: Variable EROOT should be quoted

dev-vcs/cvs
  UnquotedVariable: version 1.12.12-r14: 68: Variable EPREFIX should be quoted

dev-vcs/subversion
  UnquotedVariable: version 1.14.1: 93: Variable EPREFIX should be quoted

games-emulation/mgba
  UnquotedVariable: version 0.9.2: 97: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 0.9.2: 106: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 0.9.2: 109: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 0.9.3: 97: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 0.9.3: 106: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 0.9.3: 109: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 0.9.3-r1: 101: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 0.9.3-r1: 110: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 0.9.3-r1: 113: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 9999: 97: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 9999: 106: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 9999: 109: Variable BUILD_DIR should be quoted

gnome-base/gdm
  UnquotedVariable: version 41.3: 204: Variable EROOT should be quoted
  UnquotedVariable: version 42.0: 199: Variable EROOT should be quoted

gnome-base/gnome-desktop
  UnquotedVariable: version 42.0-r300: 80: Variable ED should be quoted
  UnquotedVariable: version 42.0-r300: 81: Variable ED should be quoted
  UnquotedVariable: version 42.1-r300: 77: Variable ED should be quoted
  UnquotedVariable: version 42.1-r300: 78: Variable ED should be quoted

gnustep-libs/dbuskit
  UnquotedVariable: version 0.1.1-r1: 19: Variable FILESDIR should be quoted

mail-client/neomutt
  UnquotedVariable: version 20210205-r1: 123: Variable S should be quoted
  UnquotedVariable: version 20211015: 119: Variable S should be quoted
  UnquotedVariable: version 20211022: 119: Variable S should be quoted
  UnquotedVariable: version 20211029: 119: Variable S should be quoted
  UnquotedVariable: version 20211029-r1: 128: Variable S should be quoted
  UnquotedVariable: version 20220408: 128: Variable S should be quoted
  UnquotedVariable: version 20220415: 128: Variable S should be quoted
  UnquotedVariable: version 20220429: 128: Variable S should be quoted
  UnquotedVariable: version 99999999: 128: Variable S should be quoted

media-fonts/monafont
  UnquotedVariable: version 2.90-r2: 55: Variable WORKDIR should be quoted

media-gfx/blender
  UnquotedVariable: version 2.93.0-r1: 309: Variable ED should be quoted
  UnquotedVariable: version 2.93.6: 283: Variable ED should be quoted
  UnquotedVariable: version 2.93.8-r4: 299: Variable ED should be quoted
  UnquotedVariable: version 2.93.8-r5: 302: Variable ED should be quoted
  UnquotedVariable: version 2.93.9: 301: Variable ED should be quoted
  UnquotedVariable: version 3.0.0-r1: 304: Variable ED should be quoted
  UnquotedVariable: version 3.0.1-r4: 307: Variable ED should be quoted
  UnquotedVariable: version 3.0.1-r5: 309: Variable ED should be quoted
  UnquotedVariable: version 3.1.0: 301: Variable ED should be quoted
  UnquotedVariable: version 3.1.1: 301: Variable ED should be quoted
  UnquotedVariable: version 3.1.2: 300: Variable ED should be quoted
  UnquotedVariable: version 9999: 300: Variable ED should be quoted

media-gfx/povray
  UnquotedVariable: version 3.7.0.0-r1: 76: Variable EPREFIX should be quoted
  UnquotedVariable: version 3.7.0.0-r1: 77: Variable EPREFIX should be quoted
  UnquotedVariable: version 3.7.0.0-r1: 105: Variable EROOT should be quoted
  UnquotedVariable: version 3.7.0.0-r1: 105: Variable EROOT should be quoted
  UnquotedVariable: version 3.7.0.0-r2: 73: Variable EPREFIX should be quoted
  UnquotedVariable: version 3.7.0.0-r2: 74: Variable EPREFIX should be quoted
  UnquotedVariable: version 3.7.0.0-r2: 102: Variable EROOT should be quoted
  UnquotedVariable: version 3.7.0.0-r2: 102: Variable EROOT should be quoted

media-gfx/tuxpaint
  UnquotedVariable: version 0.9.27: 39: Variable FILESDIR should be quoted

media-libs/libvmaf
  UnquotedVariable: version 2.3.0-r2: 41: Variable S should be quoted

media-libs/sdl2-mixer
  UnquotedVariable: version 2.0.4: 94: Variable EPREFIX should be quoted
  UnquotedVariable: version 2.0.4-r1: 95: Variable EPREFIX should be quoted

media-libs/woff2
  UnquotedVariable: version 1.0.2-r5: 32: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 1.0.2-r5: 33: Variable BUILD_DIR should be quoted
  UnquotedVariable: version 1.0.2-r5: 34: Variable BUILD_DIR should be quoted

media-sound/mixxx
  UnquotedVariable: version 2.3.2: 154: Variable DISTDIR should be quoted
  UnquotedVariable: version 2.3.9999: 152: Variable DISTDIR should be quoted

media-video/vdr
  UnquotedVariable: version 2.2.0-r6: 77: Variable T should be quoted
  UnquotedVariable: version 2.2.0-r6: 97: Variable S should be quoted
  UnquotedVariable: version 2.2.0-r7: 77: Variable T should be quoted
  UnquotedVariable: version 2.2.0-r7: 97: Variable S should be quoted
  UnquotedVariable: version 2.4.7-r1: 68: Variable S should be quoted

media-video/wireplumber
  UnquotedVariable: version 0.4.9: 89: Variable ED should be quoted
  UnquotedVariable: version 0.4.9-r1: 94: Variable ED should be quoted
  UnquotedVariable: version 0.4.10: 91: Variable ED should be quoted
  UnquotedVariable: version 0.4.10-r1: 95: Variable ED should be quoted
  UnquotedVariable: version 9999: 91: Variable ED should be quoted

net-analyzer/ipguard
  UnquotedVariable: version 1.04-r1: 34: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.04-r1: 41: Variable EPREFIX should be quoted

net-ftp/lftp
  UnquotedVariable: version 4.9.2: 79: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 77: Variable EPREFIX should be quoted

net-irc/znc-clientbuffer
  UnquotedVariable: version 1.0.48: 24: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.0.48: 34: Variable ED should be quoted

net-mail/automx2
  UnquotedVariable: version 2021.6: 39: Variable S should be quoted
  UnquotedVariable: version 2021.6: 39: Variable S should be quoted
  UnquotedVariable: version 2021.6: 40: Variable S should be quoted
  UnquotedVariable: version 2022.0: 38: Variable S should be quoted
  UnquotedVariable: version 2022.0: 38: Variable S should be quoted
  UnquotedVariable: version 2022.0: 39: Variable S should be quoted
  UnquotedVariable: version 2022.1: 39: Variable S should be quoted
  UnquotedVariable: version 2022.1: 39: Variable S should be quoted
  UnquotedVariable: version 2022.1: 40: Variable S should be quoted

net-mail/relay-ctrl
  UnquotedVariable: version 3.1.1-r2: 55: Variable D should be quoted
  UnquotedVariable: version 3.1.1-r2: 57: Variable D should be quoted
  UnquotedVariable: version 3.1.1-r3: 57: Variable D should be quoted
  UnquotedVariable: version 3.1.1-r3: 59: Variable D should be quoted
  UnquotedVariable: version 3.1.1-r3: 62: Variable D should be quoted
  UnquotedVariable: version 3.2: 58: Variable D should be quoted
  UnquotedVariable: version 3.2: 60: Variable D should be quoted
  UnquotedVariable: version 3.2: 63: Variable D should be quoted

net-print/cnijfilter2
  UnquotedVariable: version 5.90: 69: Variable S should be quoted

net-proxy/haproxy
  UnquotedVariable: version 2.4.14: 102: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.4.14: 103: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.4.14: 108: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.4.14: 110: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.4.17: 100: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.4.17: 101: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.4.17: 106: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.4.17: 108: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.4.9999: 100: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.4.9999: 101: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.4.9999: 106: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.4.9999: 108: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.4: 102: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.4: 103: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.4: 108: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.4: 110: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.7: 100: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.7: 101: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.7: 106: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.7: 108: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.9999: 100: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.9999: 101: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.9999: 106: Variable ESYSROOT should be quoted
  UnquotedVariable: version 2.5.9999: 108: Variable ESYSROOT should be quoted
  UnquotedVariable: version 9999: 100: Variable ESYSROOT should be quoted
  UnquotedVariable: version 9999: 101: Variable ESYSROOT should be quoted
  UnquotedVariable: version 9999: 106: Variable ESYSROOT should be quoted
  UnquotedVariable: version 9999: 108: Variable ESYSROOT should be quoted

net-wireless/crackle
  UnquotedVariable: version 0.1-r1: 22: Variable FILESDIR should be quoted

net-wireless/iwd
  UnquotedVariable: version 1.26: 180: Variable ED should be quoted
  UnquotedVariable: version 1.27: 180: Variable ED should be quoted
  UnquotedVariable: version 9999: 180: Variable ED should be quoted

sci-astronomy/pyephem
  UnquotedVariable: version 3.7.7.1: 37: Variable BUILD_DIR should be quoted

sci-biology/hmmer
  UnquotedVariable: version 2.3.2-r4: 27: Variable TMPDIR should be quoted

sci-chemistry/molequeue
  UnquotedVariable: version 0.9.0-r1: 56: Variable EPREFIX should be quoted

sci-libs/libsc
  UnquotedVariable: version 2.3.1-r1: 58: Variable S should be quoted
  UnquotedVariable: version 2.3.3: 58: Variable S should be quoted

sci-libs/p4est
  UnquotedVariable: version 2.3.1-r1: 66: Variable S should be quoted
  UnquotedVariable: version 2.3.3: 66: Variable S should be quoted

sec-keys/openpgp-keys-voikko
  UnquotedVariable: version 20201013: 18: Variable DISTDIR should be quoted

sec-policy/selinux-base-policy
  UnquotedVariable: version 2.20220106-r1: 60: Variable S should be quoted
  UnquotedVariable: version 2.20220106-r1: 61: Variable S should be quoted
  UnquotedVariable: version 2.20220106-r2: 60: Variable S should be quoted
  UnquotedVariable: version 2.20220106-r2: 61: Variable S should be quoted
  UnquotedVariable: version 2.20220106-r3: 60: Variable S should be quoted
  UnquotedVariable: version 2.20220106-r3: 61: Variable S should be quoted
  UnquotedVariable: version 9999: 60: Variable S should be quoted
  UnquotedVariable: version 9999: 61: Variable S should be quoted

sys-apps/nvme-cli
  UnquotedVariable: version 2.0: 31: Variable EPREFIX should be quoted

sys-auth/elogind
  UnquotedVariable: version 246.10-r1: 69: Variable EPREFIX should be quoted

sys-auth/libfprint
  UnquotedVariable: version 1.0: 30: Variable FILESDIR should be quoted

sys-block/flashbench
  UnquotedVariable: version 20120606: 13: Variable FILESDIR should be quoted

sys-boot/milo
  UnquotedVariable: version 2.4.18: 96: Variable WORKDIR should be quoted
  UnquotedVariable: version 2.4.18: 97: Variable WORKDIR should be quoted
  UnquotedVariable: version 2.4.18: 98: Variable S should be quoted
  UnquotedVariable: version 2.4.18: 141: Variable S should be quoted
  UnquotedVariable: version 2.4.18: 157: Variable S should be quoted
  UnquotedVariable: version 2.4.18: 158: Variable WORKDIR should be quoted
  UnquotedVariable: version 2.4.18: 159: Variable WORKDIR should be quoted
  UnquotedVariable: version 2.4.18: 168: Variable WORKDIR should be quoted
  UnquotedVariable: version 2.4.18: 176: Variable FILESDIR should be quoted
  UnquotedVariable: version 2.4.18: 176: Variable WORKDIR should be quoted
  UnquotedVariable: version 2.4.18: 179: Variable WORKDIR should be quoted
  UnquotedVariable: version 2.4.18: 180: Variable WORKDIR should be quoted
  UnquotedVariable: version 2.4.18: 194: Variable S should be quoted
  UnquotedVariable: version 2.4.18: 197: Variable S should be quoted
  UnquotedVariable: version 2.4.18: 200: Variable DISTDIR should be quoted
  UnquotedVariable: version 2.4.18: 200: Variable S should be quoted
  UnquotedVariable: version 2.4.18: 201: Variable DISTDIR should be quoted
  UnquotedVariable: version 2.4.18: 201: Variable S should be quoted
  UnquotedVariable: version 2.4.18: 207: Variable S should be quoted
  UnquotedVariable: version 2.4.18: 217: Variable S should be quoted
  UnquotedVariable: version 2.4.18: 220: Variable DISTDIR should be quoted
  UnquotedVariable: version 2.4.18: 220: Variable FILESDIR should be quoted
  UnquotedVariable: version 2.4.18: 220: Variable FILESDIR should be quoted

sys-cluster/c3
  UnquotedVariable: version 4.0.1: 41: Variable D should be quoted
  UnquotedVariable: version 4.0.1: 42: Variable D should be quoted

sys-cluster/sanlock
  UnquotedVariable: version 3.8.2: 30: Variable FILESDIR should be quoted

sys-devel/binutils-apple
  UnquotedVariable: version 3.2.6: 203: Variable D should be quoted
  UnquotedVariable: version 3.2.6: 204: Variable EPREFIX should be quoted
  UnquotedVariable: version 3.2.6: 205: Variable EPREFIX should be quoted
  UnquotedVariable: version 3.2.6: 206: Variable EPREFIX should be quoted
  UnquotedVariable: version 3.2.6: 207: Variable EPREFIX should be quoted
  UnquotedVariable: version 3.2.6: 208: Variable EPREFIX should be quoted
  UnquotedVariable: version 3.2.6: 212: Variable D should be quoted
  UnquotedVariable: version 3.2.6: 213: Variable EPREFIX should be quoted
  UnquotedVariable: version 3.2.6: 214: Variable EPREFIX should be quoted
  UnquotedVariable: version 3.2.6: 215: Variable EPREFIX should be quoted
  UnquotedVariable: version 8.2.1-r1: 266: Variable D should be quoted
  UnquotedVariable: version 8.2.1-r1: 267: Variable EPREFIX should be quoted
  UnquotedVariable: version 8.2.1-r1: 268: Variable EPREFIX should be quoted
  UnquotedVariable: version 8.2.1-r1: 269: Variable EPREFIX should be quoted
  UnquotedVariable: version 8.2.1-r1: 270: Variable EPREFIX should be quoted
  UnquotedVariable: version 8.2.1-r1: 271: Variable EPREFIX should be quoted
  UnquotedVariable: version 8.2.1-r1: 275: Variable D should be quoted
  UnquotedVariable: version 8.2.1-r1: 276: Variable EPREFIX should be quoted
  UnquotedVariable: version 8.2.1-r1: 277: Variable EPREFIX should be quoted
  UnquotedVariable: version 8.2.1-r1: 278: Variable EPREFIX should be quoted

sys-devel/gcc-apple
  UnquotedVariable: version 4.2.1_p5666-r3: 320: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.2.1_p5666-r3: 322: Variable EPREFIX should be quoted

sys-devel/llvm-roc
  UnquotedVariable: version 4.0.0: 41: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.0.0-r2: 42: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.0.1: 42: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.1.0: 42: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.1.1: 42: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.2.0: 42: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.3.0-r1: 43: Variable EPREFIX should be quoted
  UnquotedVariable: version 4.5.2: 43: Variable EPREFIX should be quoted
  UnquotedVariable: version 5.0.2: 43: Variable EPREFIX should be quoted

sys-libs/compiler-rt
  UnquotedVariable: version 12.0.1: 100: Variable EPREFIX should be quoted
  UnquotedVariable: version 13.0.1: 113: Variable EPREFIX should be quoted
  UnquotedVariable: version 14.0.1: 113: Variable EPREFIX should be quoted
  UnquotedVariable: version 14.0.3: 115: Variable EPREFIX should be quoted
  UnquotedVariable: version 15.0.0.9999: 115: Variable EPREFIX should be quoted

sys-libs/musl
  UnquotedVariable: version 1.2.2-r8: 99: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.2.2-r8: 100: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.2.2-r8: 132: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.2.3: 99: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.2.3: 100: Variable EPREFIX should be quoted
  UnquotedVariable: version 1.2.3: 132: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 99: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 100: Variable EPREFIX should be quoted
  UnquotedVariable: version 9999: 132: Variable EPREFIX should be quoted

www-apps/miniflux
  UnquotedVariable: version 2.0.36: 91: Variable EROOT should be quoted

www-apps/nanoc-core
  UnquotedVariable: version 4.11.12: 60: Variable T should be quoted
  UnquotedVariable: version 4.12.2: 66: Variable T should be quoted
  UnquotedVariable: version 4.12.3: 66: Variable T should be quoted
  UnquotedVariable: version 4.12.5: 66: Variable T should be quoted

www-plugins/browserpass
  UnquotedVariable: version 3.0.9: 25: Variable EPREFIX should be quoted

www-client/seamonkey
  UnquotedVariable: version 2.53.10.2: 521: Variable T should be quoted
  UnquotedVariable: version 2.53.11: 516: Variable T should be quoted
  UnquotedVariable: version 2.53.11-r1: 516: Variable T should be quoted
  UnquotedVariable: version 2.53.11.1: 506: Variable T should be quoted
  UnquotedVariable: version 2.53.12: 537: Variable T should be quoted

x11-plugins/wmwork
  UnquotedVariable: version 0.2.5-r1: 23: Variable FILESDIR should be quoted

@laumann
Copy link
Copy Markdown
Contributor Author

laumann commented May 24, 2022

Updated to check eclasses as well:

eclass
  EclassUnquotedVariable: bzr: 37: Variable DISTDIR should be quoted
  EclassUnquotedVariable: bzr: 42: Variable WORKDIR should be quoted
  EclassUnquotedVariable: gnustep-base: 258: Variable EPREFIX should be quoted
  EclassUnquotedVariable: gstreamer-meson: 396: Variable BUILD_DIR should be quoted
  EclassUnquotedVariable: haskell-cabal: 324: Variable EPREFIX should be quoted
  EclassUnquotedVariable: haskell-cabal: 610: Variable EPREFIX should be quoted
  EclassUnquotedVariable: kodi-addon: 31: Variable EPREFIX should be quoted
  EclassUnquotedVariable: myspell-r2: 68: Variable DISTDIR should be quoted
  EclassUnquotedVariable: office-ext-r1: 71: Variable DISTDIR should be quoted
  EclassUnquotedVariable: ruby-ng: 654: Variable EPREFIX should be quoted
  EclassUnquotedVariable: ruby-ng-gnome2: 121: Variable EPREFIX should be quoted
  EclassUnquotedVariable: selinux-policy-2: 190: Variable S should be quoted
  EclassUnquotedVariable: selinux-policy-2: 191: Variable S should be quoted
  EclassUnquotedVariable: selinux-policy-2: 192: Variable S should be quoted
  EclassUnquotedVariable: selinux-policy-2: 194: Variable S should be quoted
  EclassUnquotedVariable: vdr-plugin-2: 279: Variable S should be quoted
  EclassUnquotedVariable: vdr-plugin-2: 608: Variable D should be quoted
  EclassUnquotedVariable: webapp: 204: Variable D should be quoted

Comment thread src/pkgcheck/checks/codingstyle.py Outdated
Comment thread src/pkgcheck/checks/codingstyle.py Outdated
Comment thread src/pkgcheck/checks/codingstyle.py Outdated
Comment thread src/pkgcheck/checks/codingstyle.py
Comment thread src/pkgcheck/checks/codingstyle.py Outdated
Comment thread src/pkgcheck/checks/codingstyle.py Outdated
Comment thread src/pkgcheck/checks/codingstyle.py Outdated
@laumann
Copy link
Copy Markdown
Contributor Author

laumann commented May 26, 2022

OK, so a bit of an overhaul based on @radhermit's input

  • Reorganized the class structure around {Ebuild,Eclass}UnquotedVariable
  • Each variable is reported once, with one or more lines where it should be quoted
  • tests updated

@arthurzam arthurzam self-requested a review May 26, 2022 21:25
Comment thread src/pkgcheck/checks/codingstyle.py Outdated
Comment thread src/pkgcheck/checks/codingstyle.py Outdated
Copy link
Copy Markdown
Member

@arthurzam arthurzam left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks very good and mature @laumann - thank you.
Some ideas to improve it, and also as you stated a test for eclass parsing and catching

Comment thread src/pkgcheck/checks/codingstyle.py
Comment thread src/pkgcheck/checks/codingstyle.py
Comment thread src/pkgcheck/checks/codingstyle.py Outdated
@laumann
Copy link
Copy Markdown
Contributor Author

laumann commented May 27, 2022

With the latest rewrite you can do:

pkgcheck scan -k UnquotedVariable

and get results for both ebuilds and eclasses:

Total: 209 (grep UnquotedVariable |wc -l)
app-accessibility/sound-icons
  UnquotedVariable: version 0.1: unquoted variable S on line: 25 

app-admin/salt
  UnquotedVariable: version 3003-r1: unquoted variable TMPDIR on lines: 164, 167 
  UnquotedVariable: version 3003.3: unquoted variable TMPDIR on lines: 171, 174 
  UnquotedVariable: version 3003.3-r1: unquoted variable TMPDIR on lines: 172, 175 
  UnquotedVariable: version 3003.4-r1: unquoted variable TMPDIR on lines: 174, 177 
  UnquotedVariable: version 3004.1-r4: unquoted variable TMPDIR on lines: 176, 179 

app-antivirus/lkrg
  UnquotedVariable: version 0.9.2: unquoted variable DISTDIR on line: 36 
  UnquotedVariable: version 0.9.3: unquoted variable DISTDIR on line: 34 

app-arch/alien
  UnquotedVariable: version 8.95-r1: unquoted variable D on line: 32 

app-backup/tsm
  UnquotedVariable: version 8.1.13.3: unquoted variable D on lines: 184, 185, 188, 189, 190 

app-cdr/dvdisaster
  UnquotedVariable: version 0.79.5: unquoted variable ED on line: 81 

app-containers/lxd
  UnquotedVariable: version 4.0.9-r3: unquoted variable S on line: 128 

app-crypt/libsecret
  UnquotedVariable: version 0.20.5-r3: unquoted variable BROOT on line: 75 

app-crypt/p11-kit
  UnquotedVariable: version 0.23.22: unquoted variable EPREFIX on line: 47 
  UnquotedVariable: version 0.24.1: unquoted variable EPREFIX on line: 47 

app-editors/qhexedit2
  UnquotedVariable: version 0.8.6_p20190316-r1: unquoted variable S on lines: 71, 93 
  UnquotedVariable: version 0.8.9_p20210525-r1: unquoted variable S on lines: 73, 95 

app-misc/mc
  UnquotedVariable: version 9999: unquoted variable S on line: 66 

app-misc/tdl
  UnquotedVariable: version 1.5.2-r3: unquoted variable EPREFIX on line: 44 

app-shells/bash
  UnquotedVariable: version 4.3_p48-r2: unquoted variable EPREFIX on lines: 120, 121, 122, 123 
  UnquotedVariable: version 4.4_p23-r2: unquoted variable EPREFIX on lines: 129, 130, 131, 132 
  UnquotedVariable: version 5.0_p18: unquoted variable EPREFIX on lines: 133, 134, 135, 136 
  UnquotedVariable: version 5.1_p16: unquoted variable EPREFIX on lines: 140, 141, 142, 143 
  UnquotedVariable: version 5.2_beta: unquoted variable EPREFIX on lines: 153, 154, 155, 156 
  UnquotedVariable: version 9999: unquoted variable EPREFIX on lines: 153, 154, 155, 156 

dev-db/myodbc
  UnquotedVariable: version 8.0.27-r1: unquoted variable EPREFIX on line: 56 

dev-db/pgtap
  UnquotedVariable: version 1.2.0-r2: unquoted variable ED on line: 36 

dev-embedded/libftd2xx
  UnquotedVariable: version 1.4.8: unquoted variable ED on line: 34 

dev-haskell/language-haskell-extract
  UnquotedVariable: version 0.2.4-r1: unquoted variable FILESDIR on line: 25 

dev-haskell/wcwidth
  UnquotedVariable: version 0.0.2: unquoted variable FILESDIR on line: 29 

dev-lang/gforth
  UnquotedVariable: version 0.7.3-r2: unquoted variable EPREFIX on line: 39 

dev-lang/mlton
  UnquotedVariable: version 20180207: unquoted variable S on line: 91 

dev-lang/lua
  UnquotedVariable: version 5.1.5-r106: unquoted variable EPREFIX on line: 80 
  UnquotedVariable: version 5.1.5-r107: unquoted variable EPREFIX on line: 85 
  UnquotedVariable: version 5.3.6-r2: unquoted variable EPREFIX on line: 71 
  UnquotedVariable: version 5.3.6-r3: unquoted variable EPREFIX on line: 76 
  UnquotedVariable: version 5.4.2-r1: unquoted variable EPREFIX on line: 67 
  UnquotedVariable: version 5.4.2-r2: unquoted variable EPREFIX on line: 72 
  UnquotedVariable: version 5.4.4: unquoted variable EPREFIX on line: 72 

dev-lang/teyjus
  UnquotedVariable: version 2.1: unquoted variable EPREFIX on line: 86 
  UnquotedVariable: version 2.1-r1: unquoted variable EPREFIX on line: 88 

dev-lang/spidermonkey
  UnquotedVariable: version 1.8.5-r10: unquoted variable S on line: 54 

dev-libs/libpwquality
  UnquotedVariable: version 1.4.4: unquoted variable EPREFIX on line: 34 
  UnquotedVariable: version 1.4.4-r1: unquoted variable EPREFIX on line: 33 

dev-perl/Net-Subnet
  UnquotedVariable: version 1.30.0-r2: unquoted variable FILESDIR on line: 20 

dev-perl/Tk
  UnquotedVariable: version 804.36.0: unquoted variable EPREFIX on line: 33 

dev-php/PEAR-PEAR
  UnquotedVariable: version 1.10.12: unquoted variable EPREFIX on lines: 118, 122, 126, 130, 134 
  UnquotedVariable: version 1.10.13: unquoted variable EPREFIX on lines: 118, 122, 126, 130, 134 

dev-python/shiboken2
  UnquotedVariable: version 5.15.2-r1: unquoted variable EPREFIX on lines: 80, 99 

dev-python/tpm2-pytss
  UnquotedVariable: version 1.1.0: unquoted variable S on line: 39 
  UnquotedVariable: version 1.1.0: unquoted variable T on line: 37 

dev-ruby/hiera-eyaml
  UnquotedVariable: version 3.1.1: unquoted variable S on line: 42 
  UnquotedVariable: version 3.1.1: unquoted variable T on line: 34 
  UnquotedVariable: version 3.2.2: unquoted variable S on line: 43 
  UnquotedVariable: version 3.2.2: unquoted variable T on line: 34 

dev-ruby/hiredis
  UnquotedVariable: version 0.6.3-r1: unquoted variable T on line: 36 

dev-ruby/ruby-mp3info
  UnquotedVariable: version 0.8.10-r1: unquoted variable T on line: 27 

dev-ruby/rubyzip
  UnquotedVariable: version 1.3.0: unquoted variable T on line: 45 
  UnquotedVariable: version 2.3.2-r1: unquoted variable T on line: 47 

dev-ruby/sassc
  UnquotedVariable: version 2.4.0-r1: unquoted variable ESYSROOT on line: 37 

dev-scheme/kawa
  UnquotedVariable: version 1.14-r2: unquoted variable WORKDIR on line: 71 

dev-util/nvidia-cuda-toolkit
  UnquotedVariable: version 11.5.1-r1: unquoted variable EROOT on line: 224 
  UnquotedVariable: version 11.6.0: unquoted variable EROOT on line: 235 
  UnquotedVariable: version 11.6.1: unquoted variable EROOT on line: 235 
  UnquotedVariable: version 11.6.2: unquoted variable EROOT on line: 235 

dev-vcs/cvs
  UnquotedVariable: version 1.12.12-r14: unquoted variable EPREFIX on line: 68 

dev-vcs/subversion
  UnquotedVariable: version 1.14.1: unquoted variable EPREFIX on line: 93 

games-emulation/mgba
  UnquotedVariable: version 0.9.2: unquoted variable BUILD_DIR on lines: 97, 106, 109 
  UnquotedVariable: version 0.9.3: unquoted variable BUILD_DIR on lines: 97, 106, 109 
  UnquotedVariable: version 0.9.3-r1: unquoted variable BUILD_DIR on lines: 101, 110, 113 
  UnquotedVariable: version 9999: unquoted variable BUILD_DIR on lines: 97, 106, 109 

gnome-base/gdm
  UnquotedVariable: version 41.3: unquoted variable EROOT on line: 204 
  UnquotedVariable: version 42.0: unquoted variable EROOT on line: 199 

gnome-base/gnome-desktop
  UnquotedVariable: version 42.0-r300: unquoted variable ED on lines: 80, 81 
  UnquotedVariable: version 42.1-r300: unquoted variable ED on lines: 77, 78 

gnustep-libs/dbuskit
  UnquotedVariable: version 0.1.1-r1: unquoted variable FILESDIR on line: 19 

mail-client/neomutt
  UnquotedVariable: version 20211029: unquoted variable S on line: 119 
  UnquotedVariable: version 20211029-r1: unquoted variable S on line: 128 
  UnquotedVariable: version 20220408: unquoted variable S on line: 128 
  UnquotedVariable: version 20220415: unquoted variable S on line: 128 
  UnquotedVariable: version 20220429: unquoted variable S on line: 128 
  UnquotedVariable: version 99999999: unquoted variable S on line: 128 

media-fonts/monafont
  UnquotedVariable: version 2.90-r2: unquoted variable WORKDIR on line: 55 

media-gfx/blender
  UnquotedVariable: version 2.93.0-r1: unquoted variable ED on line: 309 
  UnquotedVariable: version 2.93.6: unquoted variable ED on line: 283 
  UnquotedVariable: version 2.93.8-r4: unquoted variable ED on line: 299 
  UnquotedVariable: version 2.93.8-r5: unquoted variable ED on line: 302 
  UnquotedVariable: version 2.93.9: unquoted variable ED on line: 301 
  UnquotedVariable: version 3.0.0-r1: unquoted variable ED on line: 304 
  UnquotedVariable: version 3.0.1-r4: unquoted variable ED on line: 307 
  UnquotedVariable: version 3.0.1-r5: unquoted variable ED on line: 309 
  UnquotedVariable: version 3.1.0: unquoted variable ED on line: 301 
  UnquotedVariable: version 3.1.1: unquoted variable ED on line: 301 
  UnquotedVariable: version 3.1.2: unquoted variable ED on line: 300 
  UnquotedVariable: version 9999: unquoted variable ED on line: 300 

media-gfx/povray
  UnquotedVariable: version 3.7.0.0-r1: unquoted variable EPREFIX on lines: 76, 77 
  UnquotedVariable: version 3.7.0.0-r1: unquoted variable EROOT on line: 105 
  UnquotedVariable: version 3.7.0.0-r2: unquoted variable EPREFIX on lines: 73, 74 
  UnquotedVariable: version 3.7.0.0-r2: unquoted variable EROOT on line: 102 

media-gfx/tuxpaint
  UnquotedVariable: version 0.9.27: unquoted variable FILESDIR on line: 39 

media-libs/libvmaf
  UnquotedVariable: version 2.3.0-r2: unquoted variable S on line: 41 

media-libs/sdl2-mixer
  UnquotedVariable: version 2.0.4: unquoted variable EPREFIX on line: 94 
  UnquotedVariable: version 2.0.4-r1: unquoted variable EPREFIX on line: 95 

media-libs/woff2
  UnquotedVariable: version 1.0.2-r5: unquoted variable BUILD_DIR on lines: 32, 33, 34 

media-sound/mixxx
  UnquotedVariable: version 2.3.2: unquoted variable DISTDIR on line: 154 
  UnquotedVariable: version 2.3.9999: unquoted variable DISTDIR on line: 152 

media-video/vdr
  UnquotedVariable: version 2.2.0-r6: unquoted variable S on line: 97 
  UnquotedVariable: version 2.2.0-r6: unquoted variable T on line: 77 
  UnquotedVariable: version 2.2.0-r7: unquoted variable S on line: 97 
  UnquotedVariable: version 2.2.0-r7: unquoted variable T on line: 77 
  UnquotedVariable: version 2.4.7-r1: unquoted variable S on line: 68 

media-video/wireplumber
  UnquotedVariable: version 0.4.9: unquoted variable ED on line: 89 
  UnquotedVariable: version 0.4.9-r1: unquoted variable ED on line: 94 
  UnquotedVariable: version 0.4.10: unquoted variable ED on line: 91 
  UnquotedVariable: version 0.4.10-r1: unquoted variable ED on line: 95 
  UnquotedVariable: version 0.4.10-r2: unquoted variable ED on line: 97 
  UnquotedVariable: version 9999: unquoted variable ED on line: 91 

net-analyzer/ipguard
  UnquotedVariable: version 1.04-r1: unquoted variable EPREFIX on lines: 34, 41 

net-ftp/lftp
  UnquotedVariable: version 4.9.2: unquoted variable EPREFIX on line: 79 
  UnquotedVariable: version 9999: unquoted variable EPREFIX on line: 77 

net-irc/znc-clientbuffer
  UnquotedVariable: version 1.0.48: unquoted variable ED on line: 34 
  UnquotedVariable: version 1.0.48: unquoted variable EPREFIX on line: 24 

net-mail/automx2
  UnquotedVariable: version 2022.0: unquoted variable S on lines: 38, 39 
  UnquotedVariable: version 2022.1: unquoted variable S on lines: 39, 40 

net-mail/relay-ctrl
  UnquotedVariable: version 3.1.1-r2: unquoted variable D on lines: 55, 57 
  UnquotedVariable: version 3.1.1-r3: unquoted variable D on lines: 57, 59, 62 
  UnquotedVariable: version 3.2: unquoted variable D on lines: 58, 60, 63 

net-print/cnijfilter2
  UnquotedVariable: version 5.90: unquoted variable S on line: 69 

net-proxy/haproxy
  UnquotedVariable: version 2.4.14: unquoted variable ESYSROOT on lines: 102, 103, 108, 110 
  UnquotedVariable: version 2.4.17: unquoted variable ESYSROOT on lines: 100, 101, 106, 108 
  UnquotedVariable: version 2.4.9999: unquoted variable ESYSROOT on lines: 100, 101, 106, 108 
  UnquotedVariable: version 2.5.4: unquoted variable ESYSROOT on lines: 102, 103, 108, 110 
  UnquotedVariable: version 2.5.7: unquoted variable ESYSROOT on lines: 100, 101, 106, 108 
  UnquotedVariable: version 2.5.9999: unquoted variable ESYSROOT on lines: 100, 101, 106, 108 
  UnquotedVariable: version 9999: unquoted variable ESYSROOT on lines: 100, 101, 106, 108 

net-wireless/crackle
  UnquotedVariable: version 0.1-r1: unquoted variable FILESDIR on line: 22 

net-wireless/iwd
  UnquotedVariable: version 1.26: unquoted variable ED on line: 180 
  UnquotedVariable: version 1.27: unquoted variable ED on line: 180 
  UnquotedVariable: version 9999: unquoted variable ED on line: 180 

sci-astronomy/pyephem
  UnquotedVariable: version 3.7.7.1: unquoted variable BUILD_DIR on line: 37 

sci-biology/hmmer
  UnquotedVariable: version 2.3.2-r4: unquoted variable TMPDIR on line: 27 

sci-chemistry/molequeue
  UnquotedVariable: version 0.9.0-r1: unquoted variable EPREFIX on line: 56 

sci-libs/libsc
  UnquotedVariable: version 2.3.1-r1: unquoted variable S on line: 58 
  UnquotedVariable: version 2.3.3: unquoted variable S on line: 58 

sci-libs/p4est
  UnquotedVariable: version 2.3.1-r1: unquoted variable S on line: 66 
  UnquotedVariable: version 2.3.3: unquoted variable S on line: 66 

sec-keys/openpgp-keys-voikko
  UnquotedVariable: version 20201013: unquoted variable DISTDIR on line: 18 

sec-policy/selinux-base-policy
  UnquotedVariable: version 2.20220106-r1: unquoted variable S on lines: 60, 61 
  UnquotedVariable: version 2.20220106-r2: unquoted variable S on lines: 60, 61 
  UnquotedVariable: version 2.20220106-r3: unquoted variable S on lines: 60, 61 
  UnquotedVariable: version 9999: unquoted variable S on lines: 60, 61 

sys-apps/nvme-cli
  UnquotedVariable: version 2.0: unquoted variable EPREFIX on line: 31 

sys-auth/elogind
  UnquotedVariable: version 246.10-r1: unquoted variable EPREFIX on line: 69 

sys-auth/libfprint
  UnquotedVariable: version 1.0: unquoted variable FILESDIR on line: 30 

sys-block/flashbench
  UnquotedVariable: version 20120606: unquoted variable FILESDIR on line: 13 

sys-boot/milo
  UnquotedVariable: version 2.4.18: unquoted variable DISTDIR on lines: 200, 201, 220 
  UnquotedVariable: version 2.4.18: unquoted variable FILESDIR on lines: 176, 220 
  UnquotedVariable: version 2.4.18: unquoted variable S on lines: 98, 141, 157, 194, 197, 200, 201, 207, 217 
  UnquotedVariable: version 2.4.18: unquoted variable WORKDIR on lines: 96, 97, 158, 159, 168, 176, 179, 180 

sys-cluster/c3
  UnquotedVariable: version 4.0.1: unquoted variable D on lines: 41, 42 

sys-cluster/sanlock
  UnquotedVariable: version 3.8.2: unquoted variable FILESDIR on line: 30 

sys-devel/binutils-apple
  UnquotedVariable: version 3.2.6: unquoted variable D on lines: 203, 212 
  UnquotedVariable: version 3.2.6: unquoted variable EPREFIX on lines: 204, 205, 206, 207, 208, 213, 214, 215 
  UnquotedVariable: version 8.2.1-r1: unquoted variable D on lines: 266, 275 
  UnquotedVariable: version 8.2.1-r1: unquoted variable EPREFIX on lines: 267, 268, 269, 270, 271, 276, 277, 278 

sys-devel/gcc-apple
  UnquotedVariable: version 4.2.1_p5666-r3: unquoted variable EPREFIX on lines: 320, 322 

sys-devel/llvm-roc
  UnquotedVariable: version 4.0.0: unquoted variable EPREFIX on line: 41 
  UnquotedVariable: version 4.0.0-r2: unquoted variable EPREFIX on line: 42 
  UnquotedVariable: version 4.0.1: unquoted variable EPREFIX on line: 42 
  UnquotedVariable: version 4.1.0: unquoted variable EPREFIX on line: 42 
  UnquotedVariable: version 4.1.1: unquoted variable EPREFIX on line: 42 
  UnquotedVariable: version 4.2.0: unquoted variable EPREFIX on line: 42 
  UnquotedVariable: version 4.3.0-r1: unquoted variable EPREFIX on line: 43 
  UnquotedVariable: version 4.5.2: unquoted variable EPREFIX on line: 43 
  UnquotedVariable: version 5.0.2: unquoted variable EPREFIX on line: 43 

sys-libs/compiler-rt
  UnquotedVariable: version 12.0.1: unquoted variable EPREFIX on line: 100 
  UnquotedVariable: version 13.0.1: unquoted variable EPREFIX on line: 113 
  UnquotedVariable: version 14.0.1: unquoted variable EPREFIX on line: 113 
  UnquotedVariable: version 14.0.3: unquoted variable EPREFIX on line: 115 
  UnquotedVariable: version 15.0.0.9999: unquoted variable EPREFIX on line: 115 

sys-libs/musl
  UnquotedVariable: version 1.2.2-r8: unquoted variable EPREFIX on lines: 99, 100, 132 
  UnquotedVariable: version 1.2.3: unquoted variable EPREFIX on lines: 99, 100, 132 
  UnquotedVariable: version 9999: unquoted variable EPREFIX on lines: 99, 100, 132 

www-apps/miniflux
  UnquotedVariable: version 2.0.36: unquoted variable EROOT on line: 91 

www-apps/nanoc-core
  UnquotedVariable: version 4.11.12: unquoted variable T on line: 60 
  UnquotedVariable: version 4.12.2: unquoted variable T on line: 66 
  UnquotedVariable: version 4.12.3: unquoted variable T on line: 66 
  UnquotedVariable: version 4.12.5: unquoted variable T on line: 66 

www-client/seamonkey
  UnquotedVariable: version 2.53.10.2: unquoted variable T on line: 521 
  UnquotedVariable: version 2.53.11: unquoted variable T on line: 516 
  UnquotedVariable: version 2.53.11-r1: unquoted variable T on line: 516 
  UnquotedVariable: version 2.53.11.1: unquoted variable T on line: 506 
  UnquotedVariable: version 2.53.12: unquoted variable T on line: 537 

www-plugins/browserpass
  UnquotedVariable: version 3.0.9: unquoted variable EPREFIX on line: 25 

x11-plugins/wmwork
  UnquotedVariable: version 0.2.5-r1: unquoted variable FILESDIR on line: 23 

eclass
  UnquotedVariable: bzr: unquoted variable DISTDIR on line: 37 
  UnquotedVariable: bzr: unquoted variable WORKDIR on line: 42 
  UnquotedVariable: gnustep-base: unquoted variable EPREFIX on line: 258 
  UnquotedVariable: gstreamer-meson: unquoted variable BUILD_DIR on line: 396 
  UnquotedVariable: haskell-cabal: unquoted variable EPREFIX on lines: 324, 610 
  UnquotedVariable: kodi-addon: unquoted variable EPREFIX on line: 31 
  UnquotedVariable: myspell-r2: unquoted variable DISTDIR on line: 68 
  UnquotedVariable: office-ext-r1: unquoted variable DISTDIR on line: 71 
  UnquotedVariable: ruby-ng: unquoted variable EPREFIX on line: 654 
  UnquotedVariable: ruby-ng-gnome2: unquoted variable EPREFIX on line: 121 
  UnquotedVariable: selinux-policy-2: unquoted variable S on lines: 190, 191, 192, 194 
  UnquotedVariable: vdr-plugin-2: unquoted variable D on line: 608 
  UnquotedVariable: vdr-plugin-2: unquoted variable S on line: 279 
  UnquotedVariable: webapp: unquoted variable D on line: 204 

Copy link
Copy Markdown
Member

@arthurzam arthurzam left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In my opinion, this is on the finish line for being accepted and merged. Very small nit-picks before we can merge it.

Comment thread src/pkgcheck/checks/codingstyle.py Outdated
Comment thread src/pkgcheck/checks/codingstyle.py
Comment thread testdata/repos/eclass/eclass/unquotedvariable.eclass
Comment thread testdata/repos/eclass/eclass/unquotedvariable.eclass Outdated
This is based on the repoman check EbuildQuote that reports instances of
some variables that should be quoted in certain contexts.

See: https://gitweb.gentoo.org/proj/portage.git/tree/repoman/lib/repoman/modules/linechecks/quotes/quotes.py?h=portage-3.0.30
Closes: #363
Signed-off-by: Thomas Bracht Laumann Jespersen <t@laumann.xyz>
@arthurzam arthurzam closed this in eb83f7d May 27, 2022
@laumann laumann deleted the unquoted-variables branch August 1, 2022 10:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add check for unquoted variable (repoman has it)

7 participants